//math routines

const PI = 3.141592653589793;

const POS_INFTY = 1d/0d;
const NEG_INFTY = -1d/0d;
const NaN = 0d/0d;

const FPOS_INFTY = 1f/0f;
const FNEG_INFTY = -1f/0f;
const FNaN = 0f/0f;

def abs(val: Double): Double;
def sgn(val: Double): Int;
def deg2rad(val: Double): Double;
def rad2deg(val: Double): Double;
def sin(val: Double): Double;
def cos(val: Double): Double;
def tan(val: Double): Double;
def sqrt(val: Double): Double;
def ipow(val: Double, pow: Int): Double;
def exp(val: Double): Double;
def log(val: Double): Double;
def asin(val: Double): Double;
def acos(val: Double): Double;
def atan(val: Double): Double;

def ibits2f(bits: Int): Float;
def f2ibits(f: Float): Int;
def lbits2d(bits: Long): Double;
def d2lbits(d: Double): Long;
